package com.arpa.wms.mapper;

import com.arpa.wms.domain.dto.LocationBearTypeDTO;
import com.arpa.wms.domain.entity.LocationBearType;
import com.arpa.wms.domain.vo.LocationBearTypeVO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 库位承载类型 Mapper 接口
 * </p>
 *
 * @author LEO
 * @since 2020-08-03
 */
public interface LocationBearTypeMapper extends BaseMapper<LocationBearType> {

    /**
     * 查询列表
     * @param locationBearTypeDTO
     * @return
     */
    List<LocationBearTypeVO> queryList(LocationBearTypeDTO locationBearTypeDTO);

    /**
     * 查询合计,包含总数
     * @param locationBearTypeDTO
     * @return
     */
    LocationBearTypeVO queryListSum(LocationBearTypeDTO locationBearTypeDTO);

    /**
     * 根据code返回查询使用中的数据code
     * @param codesStr
     * @return
     */
    List<String> queryLocation(@Param("codesStr") String codesStr,@Param("groupCode")String groupCode);

    /**
     * 更新状态
     * @param codesStr
     * @param status
     * @return
     */
    int changeStatus(@Param("codesStr") String codesStr, @Param("status")String status,@Param("deleteFlag")String deleteFlag,@Param("groupCode")String groupCode);

     /**
      *  @author: Allen chen
      *  @Date: 2020/9/23 13:23
      *  @Description: 根据名称查询
      */
    List<LocationBearTypeVO> queryByName(String name);
    /**
     *  @author: Allen chen
     *  @Date: 2020/10/10 9:15
     *  @Description: 根据code批量查询
     */
    List<LocationBearTypeVO> getByCodes(@Param("list") List<String> list,@Param("groupCode") String groupCode);
}
